<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>测试全局变量</title>
    <script>
        window.onload=function () {
            var a=10;
            function a11() {
                var a=15;
                console.log(a);
            }
            a11();
            console.log("a="+a);
        }
    </script>
</head>
<body>
 <script></script>
</body>
</html>